import java.util.HashMap;
import java.util.Scanner;

public class Main {


    //扑克牌顺子
    public boolean IsContinuous(int[] numbers){
        HashMap<Integer,Integer> hash = new HashMap<>();
        int max = 0,min = 13;
        for (int i = 0; i < numbers.length; i++) {
            if(numbers[i]>0){
                if (hash.containsKey(numbers[i])) return false;
                else{
                    hash.put(numbers[i],i);
                    if (numbers[i]>=max) max = numbers[i];
                    if (numbers[i]<=min) min = numbers[i];
                }
            }
        }
        if ((max-min)>=5) return false;
        else return true;
    }


    //跳台阶
    public static int jump(int n){
        if (n<2) return 1;
        int[] dp = new int[n];
        dp[0] = 1;
        dp[1] = 1;
        for (int i = 2; i < n; i++) {
            dp[i] = dp[i-1]+dp[i-2];
        }
        return dp[n-1]+dp[n-2];
    }
    public static void main(String[] args) {
        Scanner in = new Scanner(System.in);
        int n = in.nextInt();
        int x = jump(n);
        System.out.println(x);
    }


    //添加逗号
    public static void main1(String[] args) {
        Scanner in =  new Scanner(System.in);
        String s = in.next();
        int n = s.length();
        for (int i = 0; i < n; i++) {
            System.out.print(s.charAt(i));
            if((n-1-i)%3 == 0 && i!=n-1){
                System.out.print(',');
            }
        }
    }

}
